/*
 * sa2d.h
 *
 *  Created on: Aug 2, 2009
 *      Author: andri
 */

#ifndef SA2D_H_
#define SA2D_H_

#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <limits.h>
#include <time.h>
#include <string.h>
#include <unistd.h>


// Physics solver
#include "chipmunk/chipmunk.h"

// Tracker header
//#include "tracker/alpha_shape.h"

// Graphics
#include "draw.h"

// Arena, Actor
#include "arena.h"
#include "actor.h"

#include "dom/Sa2dDom.h"

// Global Variables
extern cpSpace *space;
extern cpBody *staticBody;
extern FILE *restart;
extern int** actorIndex; //global numbering of the actor in set i element j
extern FILE **output;
extern double restart_time;
extern int output_time;
extern cpFloat dt;// = 1.0e-2;

////This is for glu but it will change. The fps should be a subsampling of the real simulation.11.04.2008
extern int ticks;//=0;

void run();

class sa2d {
public:
	sa2d();
	int runSim(int argc, const char **argv,configurationfile * configFile);
	virtual ~sa2d();
};

#endif /* SA2D_H_ */
